3.133 \(\int \cot ^3(e+f x) (a+a \sin (e+f x))^m \, dx\)

Optimal. Leaf size=83 \[ -\frac{(2-m) (a \sin (e+f x)+a)^{m+2} \, _2F_1(2,m+2;m+3;\sin (e+f x)+1)}{2 a^2 f (m+2)}-\frac{\csc ^2(e+f x) (a \sin (e+f x)+a)^{m+2}}{2 a^2 f} \]

[Out]

-(Csc[e + f*x]^2*(a + a*Sin[e + f*x])^(2 + m))/(2*a^2*f) - ((2 - m)*Hypergeometric2F1[2, 2 + m, 3 + m, 1 + Sin
[e + f*x]]*(a + a*Sin[e + f*x])^(2 + m))/(2*a^2*f*(2 + m))

________________________________________________________________________________________

Rubi [A]  time = 0.0685841, antiderivative size = 83, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 21, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.143, Rules used = {2707, 78, 65} \[ -\frac{(2-m) (a \sin (e+f x)+a)^{m+2} \, _2F_1(2,m+2;m+3;\sin (e+f x)+1)}{2 a^2 f (m+2)}-\frac{\csc ^2(e+f x) (a \sin (e+f x)+a)^{m+2}}{2 a^2 f} \]

Antiderivative was successfully verified.

[In]

Int[Cot[e + f*x]^3*(a + a*Sin[e + f*x])^m,x]

[Out]

-(Csc[e + f*x]^2*(a + a*Sin[e + f*x])^(2 + m))/(2*a^2*f) - ((2 - m)*Hypergeometric2F1[2, 2 + m, 3 + m, 1 + Sin
[e + f*x]]*(a + a*Sin[e + f*x])^(2 + m))/(2*a^2*f*(2 + m))

Rule 2707

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*tan[(e_.) + (f_.)*(x_)]^(p_.), x_Symbol] :> Dist[1/f, Subst[I
nt[(x^p*(a + x)^(m - (p + 1)/2))/(a - x)^((p + 1)/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x]
&& EqQ[a^2 - b^2, 0] && IntegerQ[(p + 1)/2]

Rule 78

Int[((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> -Simp[((b*e - a*f
)*(c + d*x)^(n + 1)*(e + f*x)^(p + 1))/(f*(p + 1)*(c*f - d*e)), x] - Dist[(a*d*f*(n + p + 2) - b*(d*e*(n + 1)
+ c*f*(p + 1)))/(f*(p + 1)*(c*f - d*e)), Int[(c + d*x)^n*(e + f*x)^(p + 1), x], x] /; FreeQ[{a, b, c, d, e, f,
 n}, x] && LtQ[p, -1] && ( !LtQ[n, -1] || IntegerQ[p] ||  !(IntegerQ[n] ||  !(EqQ[e, 0] ||  !(EqQ[c, 0] || LtQ
[p, n]))))

Rule 65

Int[((b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[((c + d*x)^(n + 1)*Hypergeometric2F1[-m, n +
 1, n + 2, 1 + (d*x)/c])/(d*(n + 1)*(-(d/(b*c)))^m), x] /; FreeQ[{b, c, d, m, n}, x] &&  !IntegerQ[n] && (Inte
gerQ[m] || GtQ[-(d/(b*c)), 0])

Rubi steps

\begin{align*} \int \cot ^3(e+f x) (a+a \sin (e+f x))^m \, dx &=\frac{\operatorname{Subst}\left (\int \frac{(a-x) (a+x)^{1+m}}{x^3} \, dx,x,a \sin (e+f x)\right )}{f}\\ &=-\frac{\csc ^2(e+f x) (a+a \sin (e+f x))^{2+m}}{2 a^2 f}-\frac{(2-m) \operatorname{Subst}\left (\int \frac{(a+x)^{1+m}}{x^2} \, dx,x,a \sin (e+f x)\right )}{2 f}\\ &=-\frac{\csc ^2(e+f x) (a+a \sin (e+f x))^{2+m}}{2 a^2 f}-\frac{(2-m) \, _2F_1(2,2+m;3+m;1+\sin (e+f x)) (a+a \sin (e+f x))^{2+m}}{2 a^2 f (2+m)}\\ \end{align*}

Mathematica [A]  time = 0.188158, size = 68, normalized size = 0.82 \[ -\frac{(\sin (e+f x)+1)^2 (a (\sin (e+f x)+1))^m \left ((m+2) \csc ^2(e+f x)-(m-2) \, _2F_1(2,m+2;m+3;\sin (e+f x)+1)\right )}{2 f (m+2)} \]

Antiderivative was successfully verified.

[In]

Integrate[Cot[e + f*x]^3*(a + a*Sin[e + f*x])^m,x]

[Out]

-(((2 + m)*Csc[e + f*x]^2 - (-2 + m)*Hypergeometric2F1[2, 2 + m, 3 + m, 1 + Sin[e + f*x]])*(1 + Sin[e + f*x])^
2*(a*(1 + Sin[e + f*x]))^m)/(2*f*(2 + m))

________________________________________________________________________________________

Maple [F]  time = 0.268, size = 0, normalized size = 0. \begin{align*} \int \left ( \cot \left ( fx+e \right ) \right ) ^{3} \left ( a+a\sin \left ( fx+e \right ) \right ) ^{m}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cot(f*x+e)^3*(a+a*sin(f*x+e))^m,x)

[Out]

int(cot(f*x+e)^3*(a+a*sin(f*x+e))^m,x)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (a \sin \left (f x + e\right ) + a\right )}^{m} \cot \left (f x + e\right )^{3}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(f*x+e)^3*(a+a*sin(f*x+e))^m,x, algorithm="maxima")

[Out]

integrate((a*sin(f*x + e) + a)^m*cot(f*x + e)^3, x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left ({\left (a \sin \left (f x + e\right ) + a\right )}^{m} \cot \left (f x + e\right )^{3}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(f*x+e)^3*(a+a*sin(f*x+e))^m,x, algorithm="fricas")

[Out]

integral((a*sin(f*x + e) + a)^m*cot(f*x + e)^3, x)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(f*x+e)**3*(a+a*sin(f*x+e))**m,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (a \sin \left (f x + e\right ) + a\right )}^{m} \cot \left (f x + e\right )^{3}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(f*x+e)^3*(a+a*sin(f*x+e))^m,x, algorithm="giac")

[Out]

integrate((a*sin(f*x + e) + a)^m*cot(f*x + e)^3, x)